﻿<%@ Page Language="VB" MasterPageFile="~/MasterPageExpandable.master" AutoEventWireup="false" CodeFile="Upload.aspx.vb" Inherits="ParticipantForm_Upload" title="Submit Participant Form" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>

<%@ Register src="../AJAX/PopupMessage.ascx" tagname="PopupMessage" tagprefix="uc1" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<table><tr><td colspan="3"><h1>Participant Form</h1>
   
    </td></tr>
<tr><td colspan="3" class="adminHeaderStyle">Use this page to download and upload Excel forms for Participant Information.</td></td></tr>
</table>
<table align="center" width="840px"><tr><td valign="top">
                    <table><tr><td></td><td colspan="2"><h2>Get Participant Form</h2></td></tr>
                           <tr><td></td><td colspan="2" class="adminHeaderStyle">Start typing the last name of a participant and select from the dropdown</td></tr>
                           <tr><td></td><td colspan="2"><asp:TextBox ID="ParticipantSearchTextBox" runat="server" Columns="50"></asp:TextBox></td></tr>
                           <tr><td></td><td colspan="2"><asp:Button ID="DownloadButton" runat="server" Text="Get Form" /></td></tr>
                           <tr><td colspan="3"></td></tr>
                           <tr><td colspan="3"><asp:HyperLink ID="BlankFormHyperLink" runat="server" Text="Download Blank Form" Target="_blank"></asp:HyperLink></td></tr>
                    </table>
</td>
<td style="width:30px;"></td>
<td valign="top">                <table><tr><td></td><td colspan="2"><h2>Submit Participant Form</h2></td></tr>
                           <tr><td></td><td class="adminHeaderStyle"><asp:Label ID="UploadLabel" runat="server" Text="Select Form to Submit" AssociatedControlID="FormUpload"></asp:Label></td><td><asp:FileUpload ID="FormUpload" runat="server" /></td></tr>
                           <tr><td></td><td colspan="2" align="center"><asp:Button ID="UploadButton" runat="server" Text="Submit" /></td></tr>
                           <tr><td colspan="3"></td></tr>
                    </table>
</td>
</tr>
</table>



<cc1:AutoCompleteExtender ID="AutoCompleteExtender1" runat="server"
                TargetControlID="ParticipantSearchTextBox"
                ServicePath="~/AJAX/AutoComplete.asmx"
                BehaviorId="QuickSearchEx"
                ServiceMethod="GetParticipants"
                MinimumPrefixLength="1" 
                CompletionInterval="200"
                EnableCaching="true"
                CompletionSetCount="10"
                CompletionListCssClass="autocomplete_completionListElement" 
                CompletionListItemCssClass="autocomplete_listItem" 
                CompletionListHighlightedItemCssClass="autocomplete_highlightedListItem"
                DelimiterCharacters=";, :">
                <Animations>
                    <OnShow>
                        <Sequence>
                            <%-- Make the completion list transparent and then show it --%>
                            <OpacityAction Opacity="0" />
                            <HideAction Visible="true" />
                            
                            <%--Cache the original size of the completion list the first time
                                the animation is played and then set it to zero --%>
                            <ScriptAction Script="
                                // Cache the size and setup the initial size
                                var behavior = $find('QuickSearchEx');
                                if (!behavior._height) {
                                    var target = behavior.get_completionList();
                                    behavior._height = target.offsetHeight - 2;
                                    target.style.height = '0px';
                                }" />
                            
                            <%-- Expand from 0px to the appropriate size while fading in --%>
                            <Parallel Duration=".4">
                                <FadeIn />
                                <Length PropertyKey="height" StartValue="0" EndValueScript="$find('QuickSearchEx')._height" />
                            </Parallel>
                        </Sequence>
                    </OnShow>
                    <OnHide>
                        <%-- Collapse down to 0px and fade out --%>
                        <Parallel Duration=".4">
                            <FadeOut />
                            <Length PropertyKey="height" StartValueScript="$find('QuickSearchEx')._height" EndValue="0" />
                        </Parallel>
                    </OnHide>
                </Animations>
        </cc1:AutoCompleteExtender>
         <uc1:PopupMessage ID="PopupMessage1" runat="server" />
           <asp:Button ID="ModalButton" runat="server" Text="Modal" Style="display:none;" />
   
   <asp:Panel ID="ConfirmUploadPanel" CssClass="modalPopup"  runat="server" Style="display:none;">
   <table><tr><td colspan="2"><asp:Label ID="ConfirmLabel" runat="server" Text=""></asp:Label></td></tr>
   <tr><td><asp:Button ID="ConfirmUploadButton" runat="server" Text="OK" /></td>
       <td><asp:Button ID="CancelUploadButton" runat="server" Text="Cancel" /></td></tr>
   </table>
   
   
   </asp:Panel>
   
     <cc1:ModalPopupExtender ID="ModalPopupConfirm" 
         PopupControlID="ConfirmUploadPanel" 
         TargetControlID="ModalButton" 
         CancelControlId="CancelUploadButton" 
         DropShadow="true" BackgroundCssClass="modalBackground"
         runat="server">
         </cc1:ModalPopupExtender>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder2" Runat="Server">
</asp:Content>

